<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title></title>
	</head>
	<body>
		<script>
//			var arr1 = ['class1','class2'];
//			var arr2 = ['class3','class4'];
////			concat()链接合并数组,返回值是新数组,原来的数组不变
//			var re = arr1.concat(arr2);
//			console.log(arr1,arr2,re);
			
//			var arr1 = [1,5,3,3,6];
//			var arr2 = arr1;
//			
//			arr2[1] = '新闻';
//			console.log(arr1,arr2);
			
//			复制数组
			var arr1 = [1,5,3,3,6];
			var arr2 = arr1.concat();
			
			arr2[1] = '新闻';
			console.log(arr1,arr2);
			
			
			
			
			
			
			
			
			
			
			
			
			
			
			
			
			
			
			
			
			
			
			
			
		</script>
	</body>
</html>
